/*****************************************************************
**                                                             	**
**  Copyright (C) 2004 Amlogic,Inc.                            	**
**  All rights reserved                                        	**
**        Revision : 1.0                                       	**
**                                                             	**
*****************************************************************/
#ifndef __NETMENUSETUPEVENT_H_
#define __NETMENUSETUPEVENT_H_
typedef void(*MENUPROC) (PHWND hwnd,unsigned char option_id);
typedef struct SETUP_MENU {
	/*
unsigned short ItemPos_x;
unsigned short ItemPos_y;
unsigned short ItemWidth;
unsigned short ItemHeight;
unsigned int DrawItemData;//menu draw data
unsigned short DrawItemData_type;
*/
DRAWINFO	Item_draw_info;
DRAWINFO	Option_draw_info;
/*
unsigned short optionPos_x;
unsigned short optionPos_y;
unsigned short optionWidth;
unsigned short optionHeight;
unsigned int DrawoptionData;// option draw data
unsigned short DrawoptionData_type;
*/
unsigned char Item_id;// sequence number in menu

unsigned char Option_id;//sequence number in option
unsigned char Option_id_saved;//option value saved
unsigned char OptionNum;//total option number of item


MENUPROC MenuProc;
}_SETUP_MENU_;
typedef enum{
	SETUP_BAR = 5,
	SETUP_SELECT_BAR,
	PROCESS_BAR,
	SLIDE_BAR,
	
	MENU_LANGUAGE_ITEM =9,
	SLIDESHOW_DUR_ITEM,
	SLIDESHOW_MODE_ITEM,
	MUSIC_REPEAT_ITEM,
	MOVIE_REPEAT_ITEM,
	DISPLAY_MODE_ITEM,
	TV_SYSTEM_ITEM,
	AUTORUN_ITEM,
	
	MENU_LANGUAGE_OPTION =17,	
	SLIDESHOW_DUR_OPTION,
	SLIDESHOW_MODE_OPTION,
	MUSIC_REPEAT_OPTION,
	MOVIE_REPEAT_OPTION,
	DISPLAY_MODE_OPTION,
	TV_SYSTEM_OPTION ,
	AUTORUN_OPTION = 24
	
}SETUPMENU_DRAW_AREA;
typedef enum{
	MENU_LANGUAGE_ITEM_ID = 0,
	SLIDESHOW_DUR_ITEM_ID,
	SLIDESHOW_MODE_ITEM_ID,
	MUSIC_REPEAT_ITEM_ID,
	MOVIE_REPEAT_ITEM_ID,
	DISPLAY_MODE_ITEM_ID,
#ifndef SURPORT_TVM
	TV_SYSTEM_ITEM_ID,
#endif
	AUTORUN_ITEM_ID,
#ifdef ENABLE_NETWORK
	NETWORK,
	RSS,
#endif
	DEFAULT_ITEM_ID 
}
SETUP_MENU_ID;

#define AVI_INFOBAR_NAME_LENGTH 500
#define NETMENUSETUP_HVD_720 			 0
#define NETMENUSETUP_HVD_1080       1
#define NETMENUSETUP_LANGUAGE_CHINESE 				0
#define NETMENUSETUP_LANGUAGE_ENGLISH        1
#define NETMENUSETUP_LANGUAGE_GERMAN 				2
#define NETMENUSETUP_LANGUAGE_FRENCH 				3
#define NETMENUSETUP_LANGUAGE_SWEDISH        4
#define NETMENUSETUP_LANGUAGE_RUSSIAN 				5
#define NETMENUSETUP_PICPLAYMODE_FINE 				0
#define NETMENUSETUP_PICPLAYMODE_MONOLR        1
#define NETMENUSETUP_IPSET_AUTO 				0
#define NETMENUSETUP_IPSET_MONOLR        1
#define NETMENUSETUP_IP_ADD 				0
#define NETMENUSETUP_DNS_ADD        1
#define NETMENUSETUP_MASK_ADD 				2
#define NETMENUSETUP_GATEWAY_ADD        3

#define LANGUAGE_CHINESE    1
#define LANGUAGE_ENGLISH    0
#define LANGUAGE_GERMAN			2
#define LANGUAGE_FRENCH    3
#define LANGUAGE_SWEDISH    4
#define LANGUAGE_RUSSIAN			5

//void optionStr(char **);
extern const unsigned char* ICON_MOVIE_PREV_BACKGROUND;
extern const unsigned char* ICON_TOP_BOTTOM_BACKGROUND1;
extern const unsigned char* ICON_TOP_BOTTOM_BACKGROUND2;

extern const unsigned char* ICON_SETUP_BACKGROUND;
extern const unsigned char* ICON_PROCESS_BAR;
extern const unsigned char* ICON_SETUP_TOP;
extern const unsigned char* ICON_SETUP_SELECT_BAR;
extern const unsigned char* ICON_SETUP_SELECT_BAR_DEFAULT;
extern const unsigned char* ICON_SETUP_BAR;
extern const unsigned char* ICON_SLIDE_BAR;
extern const unsigned char* ICON_FILE_FOCUS;
extern const unsigned char* ICON_FILE_LOSE;
extern const unsigned char* ICON_MOVIE_FOCUS;
extern const unsigned char* ICON_MOVIE_LOSE;
extern const unsigned char* ICON_MUSIC_FOCUS;
extern const unsigned char* ICON_MUSIC_LOSE;
extern const unsigned char* ICON_PHOTO_FOCUS;
extern const unsigned char* ICON_PHOTO_LOSE;
extern const unsigned char* ICON_TXT_FOCUS;
extern const unsigned char* ICON_TXT_LOSE;
extern const unsigned char* ICON_MOVIE_PREVIEW_ENABLE;
extern const unsigned char* ICON_SPEAKER;
extern const unsigned char* ICON_VOLUME;							
extern const unsigned char* ICON_INFO_BACKGROUNG;
extern const unsigned char* ICON_FILELIST_DOWN;
extern const unsigned char* ICON_FILELIST_INFO_BLANK;
extern const unsigned char* ICON_FILELIST_LEFT;
extern const unsigned char* ICON_FILELIST_MUSIC_BACKGROUND;
extern const unsigned char* ICON_FILELIST_RIGHT;
extern const unsigned char* ICON_FILELIST_UP;
extern const unsigned char* ICON_FILE_FILE_TYPE_FOCUS;
extern const unsigned char* ICON_FILE_FILE_TYPE_LOSE;
extern const unsigned char* ICON_FILE_MOVIE_TYPE_FOCUS;
extern const unsigned char* ICON_FILE_MOVIE_TYPE_LOSE;
extern const unsigned char* ICON_FILE_MUSIC_TYPE_FOCUS;
extern const unsigned char* ICON_FILE_MUSIC_TYPE_LOSE;
extern const unsigned char* ICON_FILE_PHOTO_TYPE_FOCUS;
extern const unsigned char* ICON_FILE_PHOTO_TYPE_LOSE;
extern const unsigned char* ICON_FILE_TOP;
extern const unsigned char* ICON_MOVIE_TOP; 
extern const unsigned char* ICON_MUSIC_TOP;
extern const unsigned char* ICON_PHOTO_TOP;
extern const unsigned char* ICON_TXT_TOP;
extern const unsigned char* ICON_MUSIC_INFO_BLANK;
extern const unsigned char* ICON_FILELIST_BAR_FOCUS;
extern const unsigned char* ICON_FILELIST_BAR_LOSE;
extern const unsigned char* ICON_FILELIST_BAR_FOCUS_PICKED;
extern const unsigned char* ICON_FILELIST_BAR_LOSE_PICKED;
extern const unsigned char* ICON_MUSIC_PLAY_BAR;
extern const unsigned char* ICON_TIME_BACGROUND;
extern const unsigned char* ICON_COMBO;
extern const unsigned char* ICON_MINIBAR_TRANS;
extern const unsigned char* ICON_UNMUTE;
extern const unsigned char* ICON_MUTE;
extern const unsigned char* ICON_INFOBAR_STATUS140;
extern const unsigned char* ICON_ROTATE_90;
extern const unsigned char* ICON_ROTATE_180;
extern const unsigned char* ICON_ROTATE_270;
extern const unsigned char* ICON_ZOOMLEVEL_8;
extern const unsigned char* ICON_ZOOMLEVEL_16;
extern const unsigned char* ICON_INFOBAR_STATUS512;
extern const unsigned char* ICON_INFOBAR_STATUS1;
extern const unsigned char* ICON_INFOBAR_BACKGROUND;
extern const unsigned char* ICON_PREV_LOSE;
extern const unsigned char* ICON_PREV_FOCUS;
extern const unsigned char* ICON_PLAY_FOCUS;
extern const unsigned char* ICON_PLAY_LOSE;
extern const unsigned char* ICON_NEXT_LOSE;
extern const unsigned char* ICON_NEXT_FOCUS;
extern const unsigned char* ICON_ROTATE_LOSE;
extern const unsigned char* ICON_ROTATE_FOCUS;
extern const unsigned char* ICON_STOP_LOSE;
extern const unsigned char* ICON_STOP_FOCUS;
extern const unsigned char* ICON_ZOOM_LOSE;
extern const unsigned char* ICON_ZOOM_FOCUS;

extern const unsigned char* ICON_X;
extern const unsigned char* ICON_X2;
extern const unsigned char* ICON_X4;
extern const unsigned char* ICON_PAUSE_LOSE;
extern const unsigned char* ICON_PAUSE_FOCUS;
extern const unsigned char* ICON_PHOTO_BACKGROUND;
extern const unsigned char* ICON_PIC_FOCUS;
extern const unsigned char* ICON_PIC_LOSE;
extern const unsigned char* ICON_VOLUME_MUTE;
extern const unsigned char* ICON_MOVIE_INFOR;
extern const unsigned char* ICON_PHOTO_INFO_BACKROUNG;
extern const unsigned char* ICON_PAGE_BACKROUNG;
extern const unsigned char* ICON_VOLUME0;
extern const unsigned char* ICON_VOLUME1;
extern const unsigned char* ICON_VOLUME2;
extern const unsigned char* ICON_VOLUME3;
extern const unsigned char* ICON_VOLUME4;
extern const unsigned char* ICON_VOLUME5;
extern const unsigned char* ICON_VOLUME6;
extern const unsigned char* ICON_VOLUME7;
extern const unsigned char* ICON_VOLUME_BLANK;
extern const unsigned char* ICON_VOLUME_SPACE;
extern const unsigned char* ICON_INFO_PLAY;
extern const unsigned char* ICON_INFO_PAUSE;
extern const unsigned char* ICON_INFO_BLANK;
extern const unsigned char* ICON_INFO_FB;
extern const unsigned char* ICON_INFO_FF;
extern const unsigned char* ICON_MUSIC_SPECTRUM_BK;
extern const unsigned char* ICON_PATH_BLANK;
extern const unsigned char* ICON_NO_FOCUS;
extern const unsigned char* ICON_YES_FOCUS;
extern const unsigned char* ICON_NO_LOSE;
extern const unsigned char* ICON_YES_LOSE;
extern const unsigned char* ICON_UPGRADE_BACKGROUND;
extern const unsigned char* ICON_UPGRADE_BLANK;
extern const unsigned char* ICON_UPGRADE_PERCENT_INFOBAR;
extern const unsigned char* ICON_COPYDEL_BIG;
extern const unsigned char* ICON_COPYDEL_BKG;
extern const unsigned char* ICON_COPYDEL_FINISHED;
extern const unsigned char* ICON_COPYDEL_FOCUS;
extern const unsigned char* ICON_COPYDEL_LOSE;
extern const unsigned char* ICON_COPYDEL_SMALL;
extern const unsigned char* ICON_COPYINGFILE1;
extern const unsigned char* ICON_COPYINGFILE2;
extern const unsigned char* ICON_COPYINGFILE_BLANK;
extern const unsigned char* ICON_60;

extern const unsigned char* ICON_MUSIC_PLAY_BAR_BK;
extern const unsigned char* ICON_2_MUSIC;
extern const unsigned char* ICON_4_MUSIC;
extern const unsigned char* ICON_8_MUSIC;
extern const unsigned char* ICON_MOVIE_BACKGROUND;
extern const unsigned char* ICON_INFOBAR_FB_FOCUS_PLBK;
extern const unsigned char* ICON_INFOBAR_FB_LOSE_PLBK;
extern const unsigned char* ICON_INFOBAR_FF_FOCUS_PLBK;
extern const unsigned char* ICON_INFOBAR_FF_LOSE_PLBK ;
extern const unsigned char* ICON_INFOBAR_STATUS512_PLBK;
extern const unsigned char* ICON_NEXT_FOCUS_PLBK;
extern const unsigned char* ICON_NEXT_LOSE_PLBK;
extern const unsigned char* ICON_PAUSE_FOCUS_PLBK;
extern const unsigned char* ICON_PAUSE_LOSE_PLBK;
extern const unsigned char* ICON_PLAY_FOCUS_PLBK;
extern const unsigned char* ICON_PLAY_LOSE_PLBK;
extern const unsigned char* ICON_PREV_FOCUS_PLBK;
extern const unsigned char* ICON_PREV_LOSE_PLBK;
extern const unsigned char* ICON_STOP_FOCUS_PLBK;
extern const unsigned char* ICON_STOP_LOSE_PLBK;
extern const unsigned char* ICON_SUB_FOCUS_PLBK;
extern const unsigned char* ICON_SUB_LOSE_PLBK;
extern const unsigned char* ICON_SUB_NO_PLBK;
extern const unsigned char* ICON_SUB_BLANK_PLBK;
extern const unsigned char* ICON_X1_PLBK;
extern const unsigned char* ICON_X2_PLBK;
extern const unsigned char* ICON_X3_PLBK;
extern const unsigned char* ICON_X4_PLBK;
extern const unsigned char* ICON_X5_PLBK;
extern const unsigned char* ICON_X_PLBK;
extern const unsigned char* ICON_ZOOM_FOCUS_PLBK;
extern const unsigned char* ICON_ZOOM_LOSE_PLBK;
extern const unsigned char* ICON_ZOOMLEVEL_PLBK;
extern const unsigned char* ICON_ZOOMLEVEL_1_PLBK;
extern const unsigned char* ICON_ZOOMLEVEL_2_PLBK;
extern const unsigned char* ICON_ZOOMLEVEL_3_PLBK;
extern const unsigned char* ICON_ZOOMLEVEL_4_PLBK;

extern const unsigned char* ICON_INFOBAR_STATUS120X32;
extern const unsigned char* ICON_INFOBAR_PLAYTIME_BACKGROUND_2;
extern const unsigned char* ICON_MUSIC_PROCESSBAR_BLANK;
extern const unsigned char* ICON_MUSIC_TIME_BLANK;
extern const unsigned char* ICON_CF_FOCUS;
extern const unsigned char* ICON_CF_LOSE;
extern const unsigned char* ICON_SD_FOCUS;
extern const unsigned char* ICON_SD_LOSE;
extern const unsigned char* ICON_USB_FOCUS;
extern const unsigned char* ICON_USB_LOSE;
extern const unsigned char* ICON_XD_LOSE;
extern const unsigned char* ICON_XD_FOCUS;
extern const unsigned char* ICON_MS_FOCUS;
extern const unsigned char* ICON_MS_LOSE;
extern const unsigned char* ICON_SETUP_FOCUS;
extern const unsigned char* ICON_SETUP_LOSE;
extern const unsigned char* ICON_DEVICEEMPTY;
extern const unsigned char* ICON_DEVICENAME_BCK;
extern const unsigned char* ICON_ARROW_EMPTY;
extern const unsigned char* ICON_LEFT_ARROW;
extern const unsigned char* ICON_RIGHT_ARROW;

extern const unsigned char* ICON_FILETYPE_NAME_BLANK;
extern const unsigned char* ICON_FILELISET_BAR_FOCUS_ROLLSTRING;
extern const unsigned char* ICON_PLAYLIST_BAR_FOCUS_ROLLSTRING;
extern const unsigned char* ICON_UNKNOW_FOCUS;
extern const unsigned char* ICON_UNKNOW_LOSE;

extern const unsigned char* ICON_ARROW_BACKGROUND_DOWN;
extern const unsigned char* ICON_ARROW_BACKGROUND_UP;
extern const unsigned char* ICON_ARROW_BACKGROUND;
extern const unsigned char* ICON_ARROW_CDBKG;
extern const unsigned char* ICON_ARROW_DOWN;
extern const unsigned char* ICON_ARROW_UP;
extern const unsigned char* ICON_ARROW_DOWN_VIDEO;
extern const unsigned char* ICON_ARROW_UP_VIDEO;
extern const unsigned char* ICON_PREV_UNSUPPORT;
extern const unsigned char* ICON_UNSUPPORT_VIDEO_CONFIG ;
extern const unsigned char* ICON_TIP_BLANK;
extern const unsigned char* ICON_SCREEN_SAVE;
extern const unsigned char* ICON_PC_CONNECT;

INT32S WinSetupOnShow(PHWND hwnd, INT32S lpParam);
INT32S WinSetupMenuOnPaint(PHWND hwnd, INT32S lpParam);


void DisplayMenuOptionFromEEPROM(PHWND hwnd);

void LoadDefaultSetting(void);

INT32S NetmenusetupOnKeyPress(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetupOnShow(PHWND hwnd, INT32S lpParam) ;

void Init_Sys_Parameter(void) ;

INT32S NetmenusetuplanguageOnShow(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetuplanguageOnKeyPress(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetuppicplaymodeOnKeyPress(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetupipsetOnShow(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetupipsetOnKeyPress(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetupipsetaddOnShow(PHWND hwnd, INT32S lpParam) ;

INT32S NetmenusetupipsetaddOnKeyPress(PHWND hwnd, INT32S lpParam) ;

INT32S WinSetNetVersionOnKeyPress(PHWND hwnd, INT32S lpParam) ;

INT32S WinSetupMenuOnShow(PHWND hwnd, INT32S lpParam);

INT32S PicturePlayModeOnKeyPress(PHWND hwnd, INT32S lpParam);

INT32S PicturePlayModeOnShow(PHWND hwnd, INT32S lpParam);

INT32S WinSetupMenuShowOnKeyPress(PHWND hwnd, INT32S lpParam);

INT32S WinMulti_display_screenOnShow(PHWND hwnd, INT32S lpParam);

INT32S WinMulti_display_screenOnKeyPress(PHWND hwnd, INT32S lpParam);

INT32S ChangeOutputModeOnshow(PHWND hwnd, INT32S lpParam);

INT32S ChangeOutputModeOnKeyPress(PHWND hwnd, INT32S lpParam);

void ChangeOutputMode();

void AWCreateAllWindow();

void LoadNewIcon();
void SetTVOutput(void);//EVAN:2007_10_11

void ChangeTV_Type();

extern const  unsigned char* ICON_FOLDER_2;         
extern const  unsigned char* ICON_MUSIC_2;          
extern const  unsigned char* ICON_PHOTO_2;          
extern const  unsigned char* ICON_MOVIE_2;          

void MuiltLanguageSwitch(PHWND hwnd,unsigned char option_id);

void SlideDurAction(PHWND hwnd,unsigned char option_id);

void SlideModeAction(PHWND hwnd,unsigned char option_id);

void MusicRepeatAction(PHWND hwnd,unsigned char option_id);

void MovieRepeatAction(PHWND hwnd,unsigned char option_id);

void DisplayModeAction(PHWND hwnd,unsigned char option_id);

void TVOutPutModeAction(PHWND hwnd,unsigned char option_id);

void AutoRunAction(PHWND hwnd,unsigned char option_id);

void DefaultAction(PHWND hwnd,unsigned char option_id);

void SwitchSlidePos();


#endif //__NETMENUSETUPEVENT_H_

